<% add_decidim_page_title(t("impersonate_new_managed_user", scope: "decidim.admin.impersonations.new")) %>
<div class="item_show__header">
  <h1 class="item_show__header-title">
    <% if creating_managed_user? %>
      <%= t(".impersonate_new_managed_user") %>
    <% else %>
      <% if @form.user.managed? %>
        <%= t(".impersonate_existing_managed_user", name: @form.user.name) %>
      <% else %>
        <%= t(".impersonate_existing_user", name: @form.user.name) %>
      <% end %>
    <% end %>
  </h1>
</div>
<div class="item__edit item__edit-1col">
  <div class="item__edit-form">
    <%= decidim_form_for(@form, url: impersonatable_user_impersonations_path, html: { class: "form form-defaults new_impersonation" }) do |f| %>
      <%= render partial: "form", object: f %>
      <div class="item__edit-sticky">
        <div class="item__edit-sticky-container">
          <%= f.submit t(".impersonate"), class: "button button__sm button__secondary" %>
        </div>
      </div>
    <% end %>
  </div>
</div>
